package com.kimu.order_service_interface.mapper;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.kimu.order_service_interface.entity.Order;

@Mapper
public interface OrderMapper extends BaseMapper<Order> {

    /**
     * 根据用户ID分页查询订单
     * @param page 分页参数
     * @param userId 用户ID
     * @return 分页订单列表
     */
    IPage<Order> getOrdersByUserId(Page<Order> page, @Param("userId") Long userId);

}
